]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
shellMountOperation: Share a style class
authorFlorian Müllner <fmuellner@gnome.org>
Sat, 15 Jul 2017 06:53:34 +0000 (08:53 +0200)
committerFlorian Müllner <fmuellner@gnome.org>
Sun, 16 Jul 2017 16:10:22 +0000 (18:10 +0200)
Two of the dialogs use virtually identical styles, so it makes sense
to reuse the actual style classes.

https://bugzilla.gnome.org/show_bug.cgi?id=784985

data/theme/gnome-shell-high-contrast.css
data/theme/gnome-shell-sass
data/theme/gnome-shell.css
js/ui/shellMountOperation.js

index c59ec4184e272fece53c2f29d9f3987ceec85172..d2ee9f0867e2f0fb9a8084ee1057e851404e5165 100644 (file)
@@ -221,8 +221,7 @@ StScrollBar {
     color: #d6d6d1;
     padding-bottom: .4em; }
 
-.show-processes-dialog-subject,
-.mount-question-dialog-subject,
+.mount-dialog-subject,
 .end-session-dialog-subject {
   font-size: 14pt; }
 
@@ -294,59 +293,53 @@ StScrollBar {
 .shell-mount-operation-icon {
   icon-size: 48px; }
 
-.show-processes-dialog,
-.mount-question-dialog {
+.mount-dialog {
   spacing: 24px; }
 
-.show-processes-dialog-subject,
-.mount-question-dialog-subject {
+.mount-dialog-subject {
   padding-top: 10px;
   padding-left: 17px;
-  padding-bottom: 6px; }
-
-.mount-question-dialog-subject {
+  padding-bottom: 6px;
   max-width: 34em; }
 
-.show-processes-dialog-subject:rtl,
-.mount-question-dialog-subject:rtl {
+.mount-dialog-subject:rtl {
   padding-left: 0px;
   padding-right: 17px; }
 
-.show-processes-dialog-description,
-.mount-question-dialog-description {
+.mount-dialog-description {
   padding-left: 17px;
   width: 28em; }
 
-.show-processes-dialog-description:rtl,
-.mount-question-dialog-description:rtl {
+.mount-dialog-description:rtl {
+  padding-left: 0px;
   padding-right: 17px; }
 
-.show-processes-dialog-app-list {
+.mount-dialog-app-list {
   max-height: 200px;
   padding-top: 24px;
   padding-left: 49px;
   padding-right: 32px; }
 
-.show-processes-dialog-app-list:rtl {
+.mount-dialog-app-list:rtl {
   padding-right: 49px;
   padding-left: 32px; }
 
-.show-processes-dialog-app-list-item {
+.mount-dialog-app-list-item {
   color: #e6e6e6; }
-  .show-processes-dialog-app-list-item:hover {
+  .mount-dialog-app-list-item:hover {
     color: #fff; }
-  .show-processes-dialog-app-list-item:ltr {
+  .mount-dialog-app-list-item:ltr {
     padding-right: 1em; }
-  .show-processes-dialog-app-list-item:rtl {
+  .mount-dialog-app-list-item:rtl {
     padding-left: 1em; }
 
-.show-processes-dialog-app-list-item-icon:ltr {
+.mount-dialog-app-list-item-icon:ltr {
   padding-right: 17px; }
 
-.show-processes-dialog-app-list-item-icon:rtl {
+.mount-dialog-app-list-item-icon:rtl {
   padding-left: 17px; }
 
-.show-processes-dialog-app-list-item-name {
+.mount-dialog-app-list-item-name {
   font-size: 10pt; }
 
 /* Password or Authentication Dialog */
index df8e38874068f8b2ff4ef1c604775e41870a612f..718b45a9c1d9490334a0230f27b1631a1706f818 160000 (submodule)
@@ -1 +1 @@
-Subproject commit df8e38874068f8b2ff4ef1c604775e41870a612f
+Subproject commit 718b45a9c1d9490334a0230f27b1631a1706f818
index c3cd040ee9b6ead5fb4ed8ee647cbdda59b30e73..555cbed77907e7ef2aadf7d445cea6d0c89f1367 100644 (file)
@@ -221,8 +221,7 @@ StScrollBar {
     color: #d6d6d1;
     padding-bottom: .4em; }
 
-.show-processes-dialog-subject,
-.mount-question-dialog-subject,
+.mount-dialog-subject,
 .end-session-dialog-subject {
   font-size: 14pt; }
 
@@ -294,59 +293,53 @@ StScrollBar {
 .shell-mount-operation-icon {
   icon-size: 48px; }
 
-.show-processes-dialog,
-.mount-question-dialog {
+.mount-dialog {
   spacing: 24px; }
 
-.show-processes-dialog-subject,
-.mount-question-dialog-subject {
+.mount-dialog-subject {
   padding-top: 10px;
   padding-left: 17px;
-  padding-bottom: 6px; }
-
-.mount-question-dialog-subject {
+  padding-bottom: 6px;
   max-width: 34em; }
 
-.show-processes-dialog-subject:rtl,
-.mount-question-dialog-subject:rtl {
+.mount-dialog-subject:rtl {
   padding-left: 0px;
   padding-right: 17px; }
 
-.show-processes-dialog-description,
-.mount-question-dialog-description {
+.mount-dialog-description {
   padding-left: 17px;
   width: 28em; }
 
-.show-processes-dialog-description:rtl,
-.mount-question-dialog-description:rtl {
+.mount-dialog-description:rtl {
+  padding-left: 0px;
   padding-right: 17px; }
 
-.show-processes-dialog-app-list {
+.mount-dialog-app-list {
   max-height: 200px;
   padding-top: 24px;
   padding-left: 49px;
   padding-right: 32px; }
 
-.show-processes-dialog-app-list:rtl {
+.mount-dialog-app-list:rtl {
   padding-right: 49px;
   padding-left: 32px; }
 
-.show-processes-dialog-app-list-item {
+.mount-dialog-app-list-item {
   color: #d6d6d1; }
-  .show-processes-dialog-app-list-item:hover {
+  .mount-dialog-app-list-item:hover {
     color: #eeeeec; }
-  .show-processes-dialog-app-list-item:ltr {
+  .mount-dialog-app-list-item:ltr {
     padding-right: 1em; }
-  .show-processes-dialog-app-list-item:rtl {
+  .mount-dialog-app-list-item:rtl {
     padding-left: 1em; }
 
-.show-processes-dialog-app-list-item-icon:ltr {
+.mount-dialog-app-list-item-icon:ltr {
   padding-right: 17px; }
 
-.show-processes-dialog-app-list-item-icon:rtl {
+.mount-dialog-app-list-item-icon:rtl {
   padding-left: 17px; }
 
-.show-processes-dialog-app-list-item-name {
+.mount-dialog-app-list-item-name {
   font-size: 10pt; }
 
 /* Password or Authentication Dialog */
index 9322a2d856823419a838917ee8e4766b6020d3cb..7327aa93382b30c421c58e10e7037cc8bf0317c3 100644 (file)
@@ -69,7 +69,7 @@ const ListItem = new Lang.Class({
 
         let layout = new St.BoxLayout({ vertical: false});
 
-        this.actor = new St.Button({ style_class: 'show-processes-dialog-app-list-item',
+        this.actor = new St.Button({ style_class: 'mount-dialog-app-list-item',
                                      can_focus: true,
                                      child: layout,
                                      reactive: true,
@@ -78,12 +78,12 @@ const ListItem = new Lang.Class({
 
         this._icon = this._app.create_icon_texture(LIST_ITEM_ICON_SIZE);
 
-        let iconBin = new St.Bin({ style_class: 'show-processes-dialog-app-list-item-icon',
+        let iconBin = new St.Bin({ style_class: 'mount-dialog-app-list-item-icon',
                                    child: this._icon });
         layout.add(iconBin);
 
         this._nameLabel = new St.Label({ text: this._app.get_name(),
-                                         style_class: 'show-processes-dialog-app-list-item-name' });
+                                         style_class: 'mount-dialog-app-list-item-name' });
         let labelBin = new St.Bin({ y_align: St.Align.MIDDLE,
                                     child: this._nameLabel });
         layout.add(labelBin);
@@ -282,7 +282,7 @@ const ShellMountQuestionDialog = new Lang.Class({
     Extends: ModalDialog.ModalDialog,
 
     _init: function(gicon) {
-        this.parent({ styleClass: 'mount-question-dialog' });
+        this.parent({ styleClass: 'mount-dialog' });
 
         let mainContentLayout = new St.BoxLayout();
         this.contentLayout.add(mainContentLayout, { x_fill: true,
@@ -299,7 +299,7 @@ const ShellMountQuestionDialog = new Lang.Class({
         mainContentLayout.add(messageLayout,
                               { y_align: St.Align.START });
 
-        this.subjectLabel = new St.Label({ style_class: 'mount-question-dialog-subject' });
+        this.subjectLabel = new St.Label({ style_class: 'mount-dialog-subject' });
         this.subjectLabel.clutter_text.ellipsize = Pango.EllipsizeMode.NONE;
         this.subjectLabel.clutter_text.line_wrap = true;
 
@@ -307,7 +307,7 @@ const ShellMountQuestionDialog = new Lang.Class({
                           { y_fill:  false,
                             y_align: St.Align.START });
 
-        this.descriptionLabel = new St.Label({ style_class: 'mount-question-dialog-description' });
+        this.descriptionLabel = new St.Label({ style_class: 'mount-dialog-description' });
         this.descriptionLabel.clutter_text.ellipsize = Pango.EllipsizeMode.NONE;
         this.descriptionLabel.clutter_text.line_wrap = true;
 
@@ -436,7 +436,7 @@ const ShellProcessesDialog = new Lang.Class({
     Extends: ModalDialog.ModalDialog,
 
     _init: function(gicon) {
-        this.parent({ styleClass: 'show-processes-dialog' });
+        this.parent({ styleClass: 'mount-dialog' });
 
         let mainContentLayout = new St.BoxLayout();
         this.contentLayout.add(mainContentLayout, { x_fill: true,
@@ -453,13 +453,13 @@ const ShellProcessesDialog = new Lang.Class({
         mainContentLayout.add(messageLayout,
                               { y_align: St.Align.START });
 
-        this.subjectLabel = new St.Label({ style_class: 'show-processes-dialog-subject' });
+        this.subjectLabel = new St.Label({ style_class: 'mount-dialog-subject' });
 
         messageLayout.add(this.subjectLabel,
                           { y_fill:  false,
                             y_align: St.Align.START });
 
-        this.descriptionLabel = new St.Label({ style_class: 'show-processes-dialog-description' });
+        this.descriptionLabel = new St.Label({ style_class: 'mount-dialog-description' });
         this.descriptionLabel.clutter_text.ellipsize = Pango.EllipsizeMode.NONE;
         this.descriptionLabel.clutter_text.line_wrap = true;
 
@@ -467,7 +467,7 @@ const ShellProcessesDialog = new Lang.Class({
                           { y_fill:  true,
                             y_align: St.Align.START });
 
-        let scrollView = new St.ScrollView({ style_class: 'show-processes-dialog-app-list'});
+        let scrollView = new St.ScrollView({ style_class: 'mount-dialog-app-list'});
         scrollView.set_policy(Gtk.PolicyType.NEVER,
                               Gtk.PolicyType.AUTOMATIC);
         this.contentLayout.add(scrollView,